package svc

import (
	"Junior_two/subject/pay/payapi/internal/config"
	"Junior_two/subject/pay/payrpc/payrpcclient"
	"github.com/zeromicro/go-zero/zrpc"
)

type ServiceContext struct {
	Config    config.Config
	PayServer payrpcclient.PayRpc
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config:    c,
		PayServer: payrpcclient.NewPayRpc(zrpc.MustNewClient(c.PayServer)),
	}
}
